package com.qidian.tcba.dao;


import com.qidian.tcba.admin.model.dto.user.RegisterDTO;
import com.qidian.tcba.admin.model.query.UserQueryDTO;
import com.qidian.tcba.admin.model.entity.User;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;
@Mapper
public interface UserMapper {
    int deleteByPrimaryKey(int id);

    int insert(User record);

    User selectByPrimaryKey(int id);

    List<User> selectAll();

    int updateByPrimaryKey(User record);

    List<User> getUsers(UserQueryDTO userQueryDTO);

    int updateStatusById(int userId,int status);

    User findByUsername(String username);

    User login(String username, String password);

    int register(RegisterDTO registerDTO);
}